//
//  KFDMyEventsViewModel.m
//  KFD
//
//  Created by JIRENTIANXIANG on 7/7/15.
//  Copyright © 2015 kfd. All rights reserved.
//

#import "KFDMyActivitiesViewModel.h"
#import "KFDClient.h"

@implementation KFDMyActivitiesViewModel

-(void)loadPreferentialActivitiesWithMaxAccount:(NSUInteger)maxAccount page:(NSUInteger)page
{
    KFDClient* client=[KFDClient sharedClient];
    [client getMyPreferentialActivitiesWithMaxCount:maxAccount page:page successHandler:^(NSArray *activities) {
        self.activities=activities;
        [[NSNotificationCenter defaultCenter] postNotificationName:KFDMyPreferentialActivitiesReadyNotification object:nil];
    } failureHandler:^(KFDResponseBody *response) {
        
    }];
}

@end
